#include "UdpDatagram.h"

UdpDatagram::UdpDatagram (char * buffer, int length, long _toa, sockaddr * client, sockaddr * server)
{
	this->destination_port = ((sockaddr_in *)server)->sin_port;
	this->source_port = ((sockaddr_in *)client)->sin_port;
	//copy the pointer of buffer
	this->buffer = buffer;
	this->length = length;
	this->toa = _toa;
}
